import { Injectable } from '@angular/core';
import {HttpClient} from "@angular/common/http";
import {Observable} from "rxjs";

@Injectable({
  providedIn: 'root'
})
export class VisitsService {
    private baseUrl = 'http://localhost:8080/index/visits';
    constructor(private http: HttpClient) {
    }

    getVisits(): Observable<any> {
        const url = `${this.baseUrl}`;
        return this.http.get<any>(url);
    }
}

